home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 14812 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.3 KB

  1. Path: mozo.cc.purdue.edu!news
  2. From: jsrobins@expert.cc.purdue.edu (J)
  3. Newsgroups: comp.lang.c++
  4. Subject: inheritance and linked lists
  5. Date: 2 Apr 1996 00:52:19 GMT
  6. Organization: Undue Perversity
  7. Message-ID: <4jpto3$k04@mozo.cc.purdue.edu>
  8. NNTP-Posting-Host: staff2.sla.purdue.edu
  9. Mime-Version: 1.0
  10. Content-Type: Text/Plain; charset=US-ASCII
  11. X-Newsreader: WinVN 0.99.6
  12.  
  13. Is there a way to form a linked list of both a base class and its dependents?
  14. In attempting to do so, I have found that a self-referencing pointer declared
  15. from within a base class cannot be used in derived classes.  As a partial
  16. solution, I could reference the pointer to the base class sub-class of the
  17. derived class (get all that?), but then the functionality of the rest of the
  18. sub-class is no longer accessible via the linked list.  Any suggestions would
  19. be greatly appreciated.  Also, I should mention that my C/C++ knowledge could
  20. use a little work (one goal of this project), so please be kind.
  21.  
  22. J
  23. -- 
  24. Microsoft Network is prohibited from redistributing this work in any form, in
  25. whole or in part. Copyright, Jay S. Robinson, 1996. License to distribute
  26. this post is available to Microsoft for $1,000. Appearance without permission
  27. constitutes an agreement to these terms. Please send notices of violation to
  28. Postmaster@microsoft.com and jsrobins@expert.cc.purdue.edu.
  29.  
  30.